import Vue from 'vue'
import App from './App.vue'
import router from './router'
import store from './store'
import 'normalize.css/normalize.css'
import '@/styles/iconfont.css'
import '@/styles/index.scss'
import {
  setupGlobalFilter,
  setupGlobalMethods,
  setupCustomComponents,
  setupGlobalExtensions,
  setupDirectives
} from '@/plugins'

Vue.config.productionTip = false
Vue.prototype.$bus = new Vue() // 全局事件总线
// 注册全局过滤
setupGlobalFilter(Vue)
// 注册全局方法
setupGlobalMethods(Vue)
// 注册自定义组件
setupCustomComponents(Vue)
// 注册全局扩展
setupGlobalExtensions(Vue)
// 注册全局自定义指令
setupDirectives(Vue)

new Vue({
  router,
  store,
  render: h => h(App)
}).$mount('#app')
